-- GENERATED SPELL FOR [Anvilrage Soldier] --


function spell0_8893(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15284,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8893', 555, 1)
end

function spell1_8893(pUnit, Event) --@Hamstring,n/a--
pUnit:FullCastSpellOnTarget(9080,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_8893', 10303, 1)
end

function spell2_8893(pUnit, Event) --@Recklessness,Self--
pUnit:FullCastSpellOnTarget(13847,pUnit)
pUnit:RegisterEvent('Sorts_8893', 15271, 1)
end

function Sorts_8893(pUnit, Event)
local choix_sorts_8893 = math.random(0, 2)
if choix_sorts_8893 == 0 then
pUnit:RegisterEvent('spell0_8893', 1, 1)
end
if choix_sorts_8893 == 1 then
pUnit:RegisterEvent('spell1_8893', 1, 1)
end
if choix_sorts_8893 == 2 then
pUnit:RegisterEvent('spell2_8893', 1, 1)
end
end

function mob8893_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_8893', math.random(1500, 3000), 1)
end

function mob8893_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob8893_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob8893_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(8893, 1, 'mob8893_Action')
RegisterUnitEvent(8893, 2, 'mob8893_Leave')
RegisterUnitEvent(8893, 3, 'mob8893_Kill')
RegisterUnitEvent(8893, 4, 'mob8893_Die')
